package it.unical.canonaco.rende.igpe.game.cbv.logiclayer.engine.actions;
/** */
class ChessboardPointCoordinate
{
	/** */
	static private final int NO_VALUE = -1;
	
	/** */
	int row;

	/** */
	int column;

	public ChessboardPointCoordinate()
	{
		row = column = NO_VALUE;
	}
	
	/** */
	public ChessboardPointCoordinate(int row, int column)
	{
		this.row = row;
		this.column = column;
	}
	
	/** */
	@Override
	public boolean equals(Object obj) {
		if(obj instanceof ChessboardPointCoordinate)
		{
			ChessboardPointCoordinate toTest = (ChessboardPointCoordinate) obj;
			System.out.println("controllo: "+this.row+"e"+this.column+" con "+toTest.row+"e"+toTest.column);
			return this.row == toTest.row && this.column == toTest.column;
		}
		return super.equals(obj);
	}

	public void reset() 
	{
			row = column = NO_VALUE;
	}
	
	public boolean isReady()
	{
		return row != NO_VALUE && column != NO_VALUE;
	}
}